package com.asm.repository;

import com.asm.entity.sys.SpotTag;
import org.springframework.data.domain.Page;
import org.springframework.data.domain.PageRequest;
import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.data.jpa.repository.Query;
import org.springframework.stereotype.Repository;

/**
 * @author morningbear
 * @description 定义广告位标签操作的接口
 * @date 2019/7/12
 */
@Repository
public interface SpotTagRepository extends JpaRepository<SpotTag,Long> {

    /**
     * 查询所有广告位标签
     *
     * @param of 分页
     * @return 广告位标签列表
     */
    @Query("select c from SpotTag c where c.isDel=false ")
    Page<SpotTag> findAll(PageRequest of);
}
